import { message } from 'antd';
import axios from '@/utils/axios';
//工序看板
export async function procedureApi(field, params) {
    return axios.get(`/ihs-gateway/basic/report/pack/production`, params);
    // return axios.get(`/api/report/${field}/production`, params)
}
export const departmentLists = async () => {
    try {
        const res = await axios.get(`/api/basic/department/department-tree`);
        const roles = res.data;
        if (res.fail) {
            message.success('获取失败');
        }
        return roles;
    }
    catch (e) {
        return e;
    }
};
export const userInfoLists = async (params) => {
    try {
        const res = await axios.post('/api/basic/staff/list', params);
        return res;
    }
    catch (e) {
        return e;
    }
};
export const moreOperation = async (staffId) => {
    try {
        const res = await axios.delete('/api/basic/staff/delete', {
            staffId
        });
        return res;
    }
    catch (e) {
        return e;
    }
};
export const operationUser = async (params) => {
    try {
        const res = await axios.post('/api/basic/staff/save', params);
        return res;
    }
    catch (e) {
        return e;
    }
};
